package cn.xtcode.test.test.rule01.factory;

import cn.xtcode.test.test.rule01.logic.RuleLogic01;
import cn.xtcode.test.test.rule01.logic.RuleLogic02;
import cn.xtcode.types.design.framework.link.model1.ILogicLink;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.checkerframework.checker.units.qual.A;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @Author xt-code
 * @Description:
 * @Create 2025/5/10 11:15
 */
@Service
public class Rule01TradeRuleFactory {
    @Resource
    private RuleLogic01 ruleLogic01;

    @Resource
    private RuleLogic02 ruleLogic02;

    public ILogicLink<String,Rule01TradeRuleFactory.DynamicContext,String> openLogicLink(){
        ruleLogic01.appendNext(new RuleLogic02());
        return ruleLogic01;
    }



    @Data
    @Builder
    @NoArgsConstructor
    @AllArgsConstructor
    public static class DynamicContext{
        private String age;
    }
}
